#pragma once

#include "ErrorContainer.h"

using namespace std;

struct CellValue{
	string operation;
	int num;
	string reduce_rule;
};

class YaccTable
{
public:
	YaccTable(string YaccOutFile);
	~YaccTable(void);
	CellValue getCell(int numInVector, string key);
private:
	int getReduceRuleNum(string str);
	void addMapToVector(map<string, CellValue> val);
	CellValue createMap(map<int, string> reduce_rules, vector<string> words);

	vector<map<string, CellValue>> m_table_string;
};
